package com.cl.cloud.binlog.factory;

import com.cl.cloud.binlog.properties.DbConfig;
import com.cl.core.common.exception.ServerException;
import com.github.shyiko.mysql.binlog.BinaryLogClient;

/**
 * @description: 获取binlog监听客户端工厂接口
 * @author: liuzijian
 * @time: 2022-07-08 11:08
 */
public interface BinaryLogClientFactory {

    /**
     * 获取客户端
     *
     * @param dbConfig 数据源配置对象
     * @return
     * @throws ServerException
     */
    BinaryLogClient getClient(DbConfig dbConfig) throws ServerException;


    void close();

}
